home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC Format 25
/
PCFormat 1993-10.iso
/
UTILS.ZIP
/
CHKEXNET.BAT
< prev
next >
Wrap
DOS Batch File
|
1992-05-20
|
853b
|
28 lines
@echo off
if "%1"=="" goto help
if not exist %1 goto no_file
echo %1 is a diskfile
goto end
:no_file
if exist %1\chkexnet.nul goto subdir
ctty nul
rem>%1\chkexnet.nul
ctty con
if not exist %1\chkexnet.nul goto no_subdir
del %1\chkexnet.nul >nul
:subdir
if exist %1\*.* echo %1 is a non-empty subdirectory
if not exist %1\*.* echo %1 is an empty subdirectory
goto end
:no_subdir
echo %1 does not exist or is write protected and can not be checked
goto end
:help
echo CHKEXNET by Jim Groeneveld, NL, 20/5-92.
echo Checks existence (or not) of some name as a disk file or subdirectory.
echo Syntax: CHKEXNET name
echo in which 'name' may be any combination of drive:path without trailing '\'.
echo To check a root dir of some drive use '\.' or 'd:\.' .
echo Output: textual report of existence, adapt for specific purposes.
:end